<div class="modal-header">
	<button type="button" class="close" data-dismiss="modal">
		<span aria-hidden="true">&times;</span><span class="sr-only">关闭</span>
	</button>
	<h4 class="modal-title">编辑用户</h4>
</div>


<form action="/user/edit" role="form" class="form-horizontal" method="post">
	<input type="hidden" name="user_id" value="{{ $userInfo->id }}">
	<input type="hidden" name="action" value="admin_edit">
	<div class="form-group">
		<label class="col-sm-3 control-label">用户名：</label>
		<div class="col-sm-6">
			<p class="form-control-static">{{$userInfo->username}}</p>
		</div>
	</div>
	<div class="form-group">
		<label class="col-sm-3 control-label">邮箱：</label>
		<div class="col-sm-6">
			<input type="text" name="email" class="form-control" value="{{ $userInfo->email }}">
		</div>

	</div>
	<div class="form-group">
		<label class="col-sm-3 control-label">角色：</label>
		<div class="col-sm-6">
			<select class="form-control" name="role">
				@foreach($roles as $role)
					@if( $userInfo->role == $role->id )
					<option value="{{ $role->id }}" selected="selected">{{ $role->name }}</option>
					@else
					<option value="{{ $role->id }}">{{ $role->name }}</option>
					@endif
				@endforeach
			</select>
		</div>

	</div>
	<div class="form-group">
		<label class="col-sm-3 control-label">密码：</label>
		<div class="col-sm-6">
			<input type="password" name="password" class="form-control">
		</div>
	</div>
	<div class="form-group">
		<label class="col-sm-3 control-label">确认密码：</label>
		<div class="col-sm-6">
			<input type="password" name="password_confirmation" class="form-control">
		</div>
	</div>
	<div class="form-group">
		<label class="col-sm-3 control-label">姓：</label>
		<div class="col-sm-6">
			<input type="text" name="firstname" class="form-control" value="{{ $userInfo->firstname }}">
		</div>
	</div>

	<div class="form-group">
		<label class="col-sm-3 control-label">名字：</label>
		<div class="col-sm-6">
			<input type="text" name="lastname" class="form-control" value="{{ $userInfo->lastname }}">
		</div>
	</div>

	<div class="form-group">
		<label class="col-sm-3 control-label">性别：</label>
		<div class="col-sm-6">
			<select class="form-control" name="sex">
				<option value="0">请选择</option>
				<option value="1" {{ $userInfo->sex == 1?'selected':'' }}>男</option>
				<option value="2" {{ $userInfo->sex == 2?'selected':'' }}>女</option>
			</select>
		</div>
	</div>

	<div class="form-group">
		<label class="col-sm-3 control-label">生日：</label>
		<div class="col-sm-6">
			<input type="text" name="birthday" class="form-control" value="{{ $userInfo->birthday }}">
		</div>
	</div>

	<div class="form-group">
		<label class="col-sm-3 control-label">自我描述：</label>
		<div class="col-sm-7">
			<textarea name="description_me" cols="30" rows="5" class="form-control">{{ $userInfo->description_me }}</textarea>
		</div>
	</div>


	<div class="modal-footer">
		{{ Form::submit('保存', array('class' => 'btn btn-primary')) }}
	</div>

</form>








